
// store.js
import { defineStore } from 'pinia'

export const useMainStore = defineStore('main', {
  state: () => {
    return { 
      systemTheme: 'light' 
    }
  },
  persist: true, // 整个状态都进行持久化
  actions: {
    increment(val) {
      this.systemTheme = val
    }
  }
})